package com.shanjupay.transaction.api;


import com.shanjupay.common.domain.BusinessException;
import com.shanjupay.paymentagent.api.dto.PaymentResponseDTO;
import com.shanjupay.transaction.api.dto.PayOrderDTO;
import com.shanjupay.transaction.api.dto.QRCodeDto;

/**
 * 交易相关服务接口
 */
public interface TransactionService {

    /**
     * 生成门店二维码的url
     *
     * @param qrCodeDto
     * @return url
     * @throws BusinessException
     */
    String createStoreQRCode(QRCodeDto qrCodeDto) throws BusinessException;

    /**
     * 保存支付宝订单接口 1.保存订单到闪聚平台 2.调用支付渠道代理服务调用支付宝的接口
     * @param payOrderDTO
     * @return
     * @throws BusinessException
     */
    PaymentResponseDTO submitOrderByAli(PayOrderDTO payOrderDTO) throws BusinessException;


    /**
     * 根据订单号查询订单
     *
     * @param tradeNo
     * @return
     */
    public PayOrderDTO queryPayOrder(String tradeNo);

}
